import * as Types from './mutation-types' /*  必须有“./” */
export default {
  login ({ commit }, data) {
    commit(Types.USER_LOGIN, data)
  },
  logout ({commit}) {
    commit(Types.USER_LOGOUT)
  },
  check ({commit}) {
    commit(Types.CHECK_LOGIN)
  },
  updateToken ({commit}, data) {
    commit(Types.UPDATE_TOKEN, data)
  },
  getToken ({commit}) {
    commit(Types.GET_TOKEN)
  },
  user ({commit}) {
    commit(Types.USER)
  }
}
